package com.runda;

import javax.servlet.MultipartConfigElement;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.MultipartConfigFactory;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.context.annotation.Bean;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.annotation.EnableScheduling;


@SpringBootApplication
@EnableAsync
@EnableScheduling
@ServletComponentScan
@MapperScan(basePackages="com.bbjob.mapper")
public class Run {
    public static void main(String[] args) throws Exception {
        SpringApplication.run(Run.class, args);
    }
    
    @Bean
    MultipartConfigElement multipartConfigElement() {  
    	MultipartConfigFactory factory = new MultipartConfigFactory();  
    	factory.setLocation("d://temp");  
    	return factory.createMultipartConfig();  
    }
}

 